home *** CD-ROM | disk | FTP | other *** search
/ Champak 86 / (Vol 86) My Disc.iso / Games / pet_1112.swf / scripts / DefineSprite_451 / frame_1 / DoAction.as
Text File  |  2009-04-14  |  2KB  |  67 lines

  1. function resetButtons()
  2. {
  3.    caurina.transitions.Tweener.addTween(doneBtn_mc,{_alpha:0,time:0.5});
  4.    caurina.transitions.Tweener.addTween(smallCorner_mc,{_y:457,time:0.5,delay:0.3});
  5.    started = false;
  6. }
  7. function showDoneBtn()
  8. {
  9.    setTimeout(function()
  10.    {
  11.       doneBtn_mc.gotoAndPlay(2);
  12.    }
  13.    ,600);
  14.    caurina.transitions.Tweener.addTween(doneBtn_mc,{_alpha:100,time:0.5,delay:0.9});
  15.    caurina.transitions.Tweener.addTween(smallCorner_mc,{_y:400,time:0.5,transition:"easeOutBounce",delay:0.6});
  16.    doneBtn_mc._visible = true;
  17. }
  18. function playAgain()
  19. {
  20.    unusedRandoms = new Array();
  21.    var _loc2_ = 0;
  22.    while(_loc2_ < 10)
  23.    {
  24.       unusedRandoms.push(_loc2_);
  25.       _loc2_ = _loc2_ + 1;
  26.    }
  27.    matches = 0;
  28.    started = false;
  29.    nextMatchNum = getUnusedRandom(unusedRandoms);
  30.    magenta.resetEverything();
  31.    magenta.isIdle = true;
  32.    if(doors_mc._currentframe != 1)
  33.    {
  34.       doors_mc.gotoAndPlay("close");
  35.    }
  36.    if(doors_mc._currentframe != 1)
  37.    {
  38.       doors_mc.gotoAndPlay("close");
  39.    }
  40.    stopAllSounds();
  41.    _root.sounds.loopSound("bmdg_gameloopv2",99999);
  42.    sounds.JOE_BMMDU_008.start();
  43.    scoreBoard_mc.gotoAndPlay(2);
  44.    gameTimeouts[69] = setTimeout(nextMatch,3800);
  45. }
  46. stop();
  47. magenta.isMagenta = true;
  48. doors_mc.onRelease = function()
  49. {
  50. };
  51. doors_mc.useHandCursor = false;
  52. eventCover_mc._visible = false;
  53. eventCover_mc.onRelease = function()
  54. {
  55. };
  56. eventCover_mc.useHandCursor = false;
  57. printBtn_mc._visible = false;
  58. doneBtn_mc.onClick = function()
  59. {
  60.    attachMovie("youDone","youDone_mc",this.getNextHighestDepth());
  61. };
  62. doneBtn_mc.onHover = function()
  63. {
  64.    sounds.stopStound("all");
  65.    sounds.done.start();
  66. };
  67.